<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <title>{:__('Scout Chain')}</title>
    <link rel="shortcut icon" href="__CDN__/assets/img/favicon.ico" type="image/x-icon">
    <script type="text/javascript">
        //适配移动端
        function resize() {
            var deviceWidth = document.documentElement.clientWidth;
            if (deviceWidth < 240) deviceWidth = 240;
            document.documentElement.style.cssText = 'font-size:' + (deviceWidth / 15) + 'px!important';
        }
        window.addEventListener('resize', resize);
        resize();
    </script>
    <!--[if !IE]>-->
    <script src="https://code.jquery.com/jquery-3.1.1.min.js"></script>
    <script src="__CDN__/assets/libs/bootstrap/dist/js/bootstrap.min.js"></script>
    <link rel="stylesheet" type="text/css" href="__CDN__/assets/libs/bootstrap/dist/css/bootstrap.min.css"/>
    <link rel="stylesheet" href="__CDN__/assets/css/scoute/indexPc.css"/>
    <!--<![endif]-->

    <!--<![if lte IE 8]>-->
    <script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
    <script src="//cdn.bootcss.com/respond.js/1.4.2/respond.js"></script>
    <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
    <script src="__CDN__/assets/libs/bootstrap/dist/js/bootstrap.min.js"></script>
    <link rel="stylesheet" type="text/css" href="__CDN__/assets/libs/bootstrap/dist/css/bootstrap.min.css"/>
    <link rel="stylesheet" href="__CDN__/assets/css/scoute/indexPc.css"/>
    <!--<![endif]-->

    <!--<![if gt IE 8]>-->
    <script src="https://code.jquery.com/jquery-3.1.1.min.js"></script>
    <script src="__CDN__/assets/libs/bootstrap/dist/js/bootstrap.min.js"></script>
    <link rel="stylesheet" type="text/css" href="__CDN__/assets/libs/bootstrap/dist/css/bootstrap.min.css"/>
    <link rel="stylesheet" href="__CDN__/assets/css/scoute/indexPc.css"/>
    <script src="__CDN__/assets/libs/layer/dist/layer.js"></script>
    <!--<![endif]-->

</head>
<body>
{include file="index/header" /}
<div class="lan">
    <div><a href="?ref=home/index&lang=en">EN</a></div>
    <div><a href="?ref=home/index&lang=zh-cn">中文</a></div>
</div>
<header>
    <div class="container-fluid">
        <div class="row">
            <img class="img-responsive" src="__CDN__/assets/img/scoute/web/home/banner_bg.png"/>
            <div class="ad">
                <h1>{:__('Harvest value')}</h1>
                <p>{:__('Sports Festival')}</p>
                <section id="bps">{:__('White Book')}</section>
            </div>
        </div>
    </div>
</header>
<div class="container-fluid introduce" id="introduce">
    <div class="row">
        <div class="col-lg-4 col-lg-offset-4 col-md-6 col-md-offset-3 col-sm-6 col-sm-offset-3">
            <h2>{:__('What is')}</h2>
            <p>{:__('Introduce1')}</p>
            <p>{:__('Introduce2')}</p>
            <p>{:__('Introduce3')}</p>
        </div>
    </div>
</div>
<div class="container-fluid user" id="user">
    <h2>{:__('Value users')}</h2>
    <div class="row">
        <div class="col-lg-4 col-lg-offset-4 col-md-6 col-md-offset-3 col-sm-6 col-sm-offset-3">
            <p class="explain">{:__('National football')}</p>
        </div>
    </div>
    <div class="">
    	<div class="row">
    		<div class="col-lg-8 col-lg-offset-2 col-md-12 user_main">
    			<div class="row">
    				<div class=" userSec1">
			            <div class="people people1">
			                <img src="__CDN__/assets/img/scoute/web/home/home_icon_value_01.png"/>
			                <p>{:__('Teenager players')}</p>
			            </div>
			            <div class="jieshao">
			                <div class="js js1">{:__('A professional')}</div>
			                <div class="js js2">{:__('To build')}</div>
			            </div>
				        <div class="dottedLine1">
				        	<div class="dottedLine1-sec1"></div>
				        	<div class="dottedLine1-sec2"></div>
				        	<div class="dottedLine1-sec3"></div>
				        	<div class="dottedLine1-sec4"></div>
				        </div>
			        </div>
    			</div>
    			<div class="row">
			        <div class="userSec2">
			            <div class="jieshao">
			                <div class="js js3">{:__('Fans can1')}</div>
			                <div class="js js4">{:__('Fans can2')}</div>
			                <div class="js js5">{:__('Fans can3')}</div>
			            </div>
			            <div class="people people2">
			                <img src="__CDN__/assets/img/scoute/web/home/home_icon_value_02.png"/>
			                <p>{:__('Fans rights')}</p>
			            </div>
			            <div class="dottedLine2">
				        	<div class="dottedLine2-sec1"></div>
				        	<div class="dottedLine2-sec2"></div>
				        	<div class="dottedLine2-sec3"><div class="dottedLine2-sec33"></div></div>
				        	<div class="dottedLine2-sec4"></div>
				        </div>
			        </div>
		    	</div>
		    	<div class="dottedLine3">
			    	<div class="dottedLine3-sec1"></div>
					<div class="dottedLine3-sec2"></div>
					<div class="dottedLine3-sec3"></div>
				</div>
    		</div>
	    </div>
    </div>
    
</div>
<div class="container-fluid serve" id="serve">
    <h2>{:__('Product service')}</h2>
    <div class="row">
        <div class="col-lg-4 col-lg-offset-4 col-md-6 col-md-offset-3 col-sm-6 col-sm-offset-3">
            <p class="explain">{:__('On the basis')}</p>
        </div>
    </div>
    <div class="row">
        <div class="col-lg-10 col-lg-offset-1 text-center serveSec1">
            <div  class="ss ss1">
                <img src="__CDN__/assets/img/scoute/web/home/home_icon_prod01.png"/>
                <h3>{:__('Open ticketing')}</h3>
                <p>{:__('The whole')}</p>
            </div>
            <div  class="ss ss2">
                <img src="__CDN__/assets/img/scoute/web/home/home_icon_prod02.png"/>
                <h3>{:__('Fair')}</h3>
                <p>{:__('The first')}</p>
            </div>
            <div  class="ss ss3">
                <img src="__CDN__/assets/img/scoute/web/home/home_icon_prod03.png"/>
                <h3>{:__('Point to')}</h3>
                <p>{:__('The platform')}</p>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="col-lg-10 col-lg-offset-1 text-center serveSec2">
            <div  class="ss ss4">
                <img src="__CDN__/assets/img/scoute/web/home/home_icon_prod04.png"/>
                <h3>{:__('Sports')}</h3>
                <p>{:__('Decentralized')}</p>
            </div>
            <div  class="ss ss5">
                <img src="__CDN__/assets/img/scoute/web/home/home_icon_prod05.png"/>
                <h3>{:__('Interactive')}</h3>
                <p>{:__('The media')}</p>
            </div>
        </div>
    </div>
</div>
<div class="container-fluid advantage" id="advantage">
    <!--<img src="__CDN__/assets/img/scoute/web/home/home_ys_bg.png"/>-->
    <h2>{:__('Advantages')}</h2>
    <div class="row row1">
        <div class="col-lg-4 col-lg-offset-4 col-md-6 col-md-offset-3 col-sm-8 col-sm-offset-2">
            <p class="explain2">{:__('Based on')}</p>
        </div>
    </div>
    <div class="row">
        <div class="col-lg-12 col-lg-offset-0 col-md-12 col-md-offset-0 col-sm-12 col-sm-offset-0 text-center advSec">
            <div  class="as as1">
                <h3>{:__('Open ticketing')}</h3>
                <p>{:__('The whole')}</p>
                <div></div>
            </div>
            <div  class="as as2">
                <h3>{:__('Fair')}</h3>
                <p>{:__('The first')}</p>
                <div></div>
            </div>
            <div  class="as as3">
                <h3>{:__('Point to')}</h3>
                <p>{:__('The platform')}</p>
                <div></div>
            </div>
        </div>
    </div>
    <div class="kongbai"></div>
</div>
<div class="container-fluid qtl" id="qtl">
    <div class="row">
        <div class="col-lg-8 col-lg-offset-2 col-md-8 col-md-offset-2 col-sm-10 col-sm-offset-1 text-center qtlSec">
            <img src="__CDN__/assets/img/scoute/web/home/home_icon_qiu.png"/>
            <div class="bz">
                <h2>{:__('Scout Chain')}</h2>
                <p>{:__('IP economy')}</p>
                <div>
                    <section class="ethBtn">ETH</section>
                    <section class="btcBtn">BTC</section>
                    {if $total lt 25000000}
                    <section class="camBtn">CAM</section>
                    {/if}
                </div>
            </div>
        </div>
    </div>
    <div class="dhxq eth">
        <div class="dhxqT"><span class="dhxqTit">{:__('Exchange')}</span><span class="dhxqClo"></span></div>
        <div class="dhbl"><span>{:__('Subscription')}：</span><span>1 ETH = {$list.eth_cts} CTS</span></div>
        <div class="dhNum">
            <div>ETH{:__('Receivables')}：</div>
            <div class="copyText" id="copyText">{$list.eth_address}</div>
            <div class="copySec">
                <textarea id="input"></textarea>
                <img class="copy" src="__CDN__/assets/img/scoute/web/home/icon_copy.png" title="{:__('Copy')}"/>
            </div>
        </div>
        <form class="dhxqForm" action="" method="">
            <div class="formGroup formGroup1">
                <label class="lab1" for="">CTS{:__('Receivables')}：</label>
                <input type="text" name="" id="sk1" placeholder="{:__('Please input receivable')}" onfocus="this.placeholder=''" onblur="this.placeholder='{:__(\'Please input receivable\')}'" autocomplete="off"/>
                <a class="yiwen" href=""><img src="__CDN__/assets/img/scoute/web/home/icon_mark.png" alt="" /></a>
                <div class="daan">{:__('How to get')}</div>
            </div>
            <div class="formGroup formGroup2">
                <label class="lab2" for="">ETH{:__('Payment')}：</label>
                <input type="text" name="" id="fk1" placeholder="{:__('Please input payment')}" onfocus="this.placeholder=''" onblur="this.placeholder='{:__(\'Please input payment\')}'" autocomplete="off"/>
            </div>
            <div class="formGroup formGroup3">
                <label class="lab3" for="">ETH{:__('Number')}：</label>
                <input type="text" name="" maxlength="10" id="cts1" placeholder="" autocomplete="off"/>
                <section><span>CTS {:__('Number')}：</span><span class="ctsNum1"></span></section>
            </div>
            <div class="btnList">
                <input class="cancel" type="button" value="{:__('Cancel')}" />
                <input class="submit" id="eth_submit" type="submit" value="{:__('Submit')}" />
            </div>
        </form>
        <div class="tishi">{:__('Copy success')}</div>
    </div>
    <div class="dhxq btc">
        <div class="dhxqT"><span class="dhxqTit">{:__('Exchange')}</span><span class="dhxqClo"></span></div>
        <div class="dhbl"><span>{:__('Subscription')}：</span><span>1 BTC = {$list.btc_cts} CTS</span></div>
        <div class="dhNum">
            <div>BTC{:__('Receivables')}：</div>
            <div class="copyText" id="copyText">
                {$list.btc_address}
            </div>
            <div class="copySec">
                <textarea id="input"></textarea>
                <img class="copy" src="__CDN__/assets/img/scoute/web/home/icon_copy.png" title="{:__('Copy')}"/>
            </div>
        </div>
        <form class="dhxqForm" action="" method="">
            <div class="formGroup formGroup1">
                <label class="lab1" for="">CTS{:__('Receivables')}：</label>
                <input type="text" name="" id="sk2" placeholder="{:__('Please input receivable')}" onfocus="this.placeholder=''" onblur="this.placeholder='{:__(\'Please input receivable\')}'" autocomplete="off"/>
                <a class="yiwen" href=""><img src="__CDN__/assets/img/scoute/web/home/icon_mark.png" alt="" /></a>
                <div class="daan">{:__('How to get')}</div>
            </div>
            <div class="formGroup formGroup2">
                <label class="lab2" for="">BTC{:__('Payment')}：</label>
                <input type="text" name="" id="fk2" placeholder="{:__('Please input payment')}" onfocus="this.placeholder=''" onblur="this.placeholder='{:__(\'Please input payment\')}'" autocomplete="off"/>
            </div>
            <div class="formGroup formGroup3">
                <label class="lab3" for="">BTC{:__('Number')}：</label>
                <input type="text" name="" id="cts2" maxlength="10" placeholder="" autocomplete="off"/>
                <section><span>CTS {:__('Number')}：</span><span class="ctsNum2"></span></section>
            </div>
            <div class="btnList">
                <input class="cancel" type="button" value="{:__('Cancel')}" />
                <input class="submit" id="btc_submit" type="submit" value="{:__('Submit')}" />
            </div>
        </form>
        <div class="tishi">{:__('Copy success')}</div>
    </div>
    <div class="dhxq cam">
        <div class="dhxqT"><span class="dhxqTit">{:__('Exchange')}</span><span class="dhxqClo"></span></div>
        <div class="dhbl"><span>{:__('Subscription')}：</span><span>1 CAM = {$list.cam_cts} CTS</span></div>
        <div class="dhNum">
            <div>CAM{:__('Receivables')}：</div>
            <div class="copyText" id="copyText">
                {$list.cam_address}
            </div>
            <div class="copySec">
                <textarea id="input"></textarea>
                <img class="copy" src="__CDN__/assets/img/scoute/web/home/icon_copy.png" title="{:__('Copy')}"/>
            </div>
        </div>
        <form class="dhxqForm" action="" method="">
            <div class="formGroup formGroup1">
                <label class="lab1" for="">CTS{:__('Receivables')}：</label>
                <input type="text" name="" id="sk3" placeholder="{:__('Please input receivable')}" onfocus="this.placeholder=''" onblur="this.placeholder='{:__(\'Please input receivable\')}'" autocomplete="off"/>
                <a class="yiwen" href=""><img src="__CDN__/assets/img/scoute/web/home/icon_mark.png" alt="" /></a>
                <div class="daan">{:__('How to get')}</div>
            </div>
            <div class="formGroup formGroup2">
                <label class="lab2" for="">CAM{:__('Payment')}：</label>
                <input type="text" name="" id="fk3" placeholder="{:__('Please input payment')}" onfocus="this.placeholder=''" onblur="this.placeholder='{:__(\'Please input payment\')}'" autocomplete="off"/>
            </div>
            <div class="formGroup formGroup3">
                <label class="lab3" for="">CAM{:__('Number')}：</label>
                <input type="text" name="" id="cts3" maxlength="10" placeholder="" autocomplete="off"/>
                <section><span>CTS {:__('Number')}：</span><span class="ctsNum3"></span></section>
            </div>
            <div class="btnList">
                <input class="cancel" type="button" value="{:__('Cancel')}" />
                <input class="submit" id="cam_submit" type="submit" value="{:__('Submit')}" />
            </div>
        </form>
        <div class="tishi">{:__('Copy success')}</div>
    </div>
</div>

<div class="container-fluid sell" id="sell">
    <div class="row">
        <div class="col-lg-10 col-lg-offset-1 text-center sellSec1">
            <h2>CTS{:__('Sales progress')}</h2>
            <div class="pro">
                <div class="percent">{$list.percentage}%</div>
                <div class="proNum"></div>
                <div class="proD"><div class="proDd"></div></div>
            </div>
            <div class="harvest">
                <section><span>{:__('Get')}ETH：</span><span>{$list.eth_num} eth</span></section>
                <section><span>{:__('Get')}BTC：</span><span>{$list.btc_num} btc</span></section>
                <section><span>{:__('Get')}CAM：</span><span>{$list.cam_num} cam</span></section>
            </div>
            <div class="search">{:__('Query')}</div>
        </div>
    </div>
    <div class="jycx">
        <div class="jycxT"><span class="jycxTxt">{:__('Transaction query')}</span><span class="jycxClo"></span></div>
        <div class="jycxH">CTS{:__('Transaction query')}</div>
        <form class="jycxForm" action="" method="">
            <input type="text" name="" id="cxInput" placeholder="{:__('Please input query')}" onfocus="this.placeholder=''" onblur="this.placeholder='请输入查询钱包地址'" autocomplete="off"/>
            <div class="btnList">
                <input class="cancel" type="button" value="{:__('Cancel')}" />
                <input class="submit query-submit"  type="submit" value="{:__('Submit')}" />
            </div>
        </form>
    </div>
    <div class="row">
        <div class="col-lg-8 col-lg-offset-2 text-center sellSec2">
            <h2>{:__('Sales plan')}</h2>
            <div class="sellSec2_S1">
                <div class="ses ses2">
                    <p class="sesp1">Start</p>
                    <p class="sesp2">{$list.start_Md}</p>
                    <p class="sesp3">{$list.start_Hi} (UTC)</p>
                </div>
                <div class="ses ses2">
                    <p class="sesp1">End</p>
                    <p class="sesp2">{$list.end_Md}</p>
                    <p class="sesp3">{$list.end_Hi} (UFC)</p>
                </div>
                <div class="ses ses3">
                    <p class="sesp1">Token Amount</p>
                    <p class="sesp2">{$list.token_amount} million</p>
                    <p class="sesp3">CTS</p>
                </div>
            </div>
            <div class="sellSec2_S2">
                {volist name="award" id="vo" key="k"}
                <div class="sec sec{$k}">
                	<canvas style="" id="yuan{$k}"></canvas>
                    <hr />
                    <span class="secp1">{:date('Y m.d',$vo.starttime)}-{:date('m.d',$vo.endtime)}</span>
                    <span class="secp2">BOUNS</span>
                </div>
                {/volist}
            </div>
        </div>
    </div>
</div>
<div class="container-fluid plan" id="plan">
    <div class="row">
        <div class="col-lg-8 col-lg-offset-2 text-center planSec">
            <div class="planM">
                <h2>{:__('Blueprint')}</h2>
                <p>{:__('Footer msg')}</p>
            </div>
        </div>
    </div>
    <div class="plan_kongbai"></div>
</div>
{include file="index/footer"}
</body>
</html>
<script type="text/javascript">
    //页面DOM结构绘制完成后执行
    var param = '{$val}';
    var plan = '{$plan}';
    var t = JSON.parse(param);//json对象序列化
    var p = JSON.parse(plan);//json对象序列化
    //查询
    $('.query-submit').click(function () {
        var vParam = $('#cxInput').val();
        var openUrl = 'https://camchain.xyz/address/'+ vParam;
        window.open(openUrl);
    });

    function openAlert(msg) {
        layer.open({
            content: msg,
            style: 'background-color:#09C1FF; color:#fff; border:none;',
            shade: false
        });
    }
    $(document).ready(function(){
        var ScrTop = document.documentElement.scrollTop || document.body.scrollTop;
        if(ScrTop > 0){
            $('.navbar').css('box-shadow','0 10px 25px rgba(0,52,74,0.18)')
        }else{
            $('.navbar').css('box-shadow','0 0 0 rgba(0,0,0,0)')
        }
    });
    //监听页面的滚动
    window.addEventListener('scroll',function(){
        var ScrTop = document.documentElement.scrollTop || document.body.scrollTop;
        if(ScrTop > 0){
            $('.navbar').css('box-shadow','0 10px 25px rgba(0,52,74,0.18)')
        }else{
            $('.navbar').css('box-shadow','0 0 0 rgba(0,0,0,0)')
        }
    });
    //导航栏鼠标停留样式
    $('.navList a').hover(function(){
        $(this).addClass('act1');
        $(this).parent().siblings().children('a').removeClass('act')
    },function(){
        $(this).removeClass('act1')
    });
    //导航栏鼠标点击样式
    $('.navList a').each(function(index,elem){
        $(this).click(function(){
            $(this).addClass('act2');
            $(this).parent().siblings().children('a').removeClass('act2');
        })
    });

    //中英文切换按钮
    $('.cutLan').click(function(){
        //取消事件冒泡
        event.stopPropagation();
        $('.lan').slideToggle(250);
    });
    //点击空白处隐藏弹出层，下面为滑动消失效果和淡出消失效果。
    $(document).click(function(event){
        var _con = $('.lan');  // 设置目标区域
        if(!_con.is(event.target) && _con.has(event.target).length === 0){ // Mark 1
            //$('#divTop').slideUp('slow');  //滑动消失
            $('.lan').slideUp(250);   //淡出消失
        }
    });
    $('.lan>div').click(function(){
        //取消事件冒泡
        event.stopPropagation();
        $('.lan').slideUp(250);
    });

    //点击eth按钮弹出框
    $('.ethBtn').click(function(){
        $('.eth').fadeIn(200);
    });
    //点击btc按钮弹出框
    $('.btcBtn').click(function(){
        $('.btc').fadeIn(200);
    });
    //点击cam按钮弹出框
    $('.camBtn').click(function(){
        $('.cam').fadeIn(200);
    });
    //点击关闭按钮关闭弹窗
    $('.dhxqClo').click(function(){
        $('.dhxq').fadeOut(200);
    });
    //点击取消按钮关闭弹窗
    $('.dhxq .cancel').click(function(){
        $('.dhxq').fadeOut(200);
    });

    //点击查询按钮弹出框
    $('.search').click(function(){
        $('.jycx').fadeIn(200);
    });
    //点击关闭按钮关闭弹窗
    $('.jycxClo').click(function(){
        $('.jycx').fadeOut(200);
    });
    //点击取消按钮关闭弹窗
    $('.jycx .cancel').click(function(){
        $('.jycx').fadeOut(200);
    });
    //ctsNum的值跟着eth输入框的值变化
    $('#cts1').keyup(function(){
        var inputNum = $('#cts1').val();
        var ethT = parseInt(t.eth_cts);
        var showNum1 = inputNum*ethT;
        $('.ctsNum1').text(showNum1);
    });
    //ctsNum的值跟着btc输入框的值变化
    $('#cts2').keyup(function(){
        var inputNum = $('#cts2').val();
        var btcT = parseInt(t.btc_cts);
        var showNum2 = inputNum*btcT;
        $('.ctsNum2').text(showNum2);
    });
    //ctsNum的值跟着cts输入框的值变化
    $('#cts3').keyup(function(){
        var inputNum = $('#cts3').val();
        var camT = parseInt(t.cam_cts);
        var showNum3 = inputNum*camT;
        $('.ctsNum3').text(showNum3);
    });
    //eth提交按钮点击事件
    $('#eth_submit').click(function () {
        var url = "{:url('home/index/assetExchange')}";
        var typeAddress = $('#fk1').val();
        var ctsAddress = $('#sk1').val();
        var ethNum = $('#cts1').val();
        var ethT = parseInt(t.eth_cts);
        var ctsExchange = ethNum*ethT;
        $.ajax({
            type: 'POST',
            url: url,
            dataType: 'json',
            data: {
                type:1,
                type_address:typeAddress,
                cts_address:ctsAddress,
                type_num:ethNum,
                cts_exchange:ctsExchange
            },
            success: function (res) {
                if ( res.code == 1 ) {
                    $('.dhxq').fadeOut(200);
                    openAlert(res.msg);
                }else {
                    openAlert(res.msg);
                }
            }
        });
        return false;
    });
    //btc提交按钮点击事件
    $('#btc_submit').click(function () {
        var url = "{:url('home/index/assetExchange')}";
        var typeAddress = $('#fk2').val();
        var ctsAddress = $('#sk2').val();
        var btcNum = $('#cts2').val();
        var btcT = parseInt(t.btc_cts);
        var ctsExchange = btcNum*btcT;
        $.ajax({
            type: 'POST',
            url: url,
            dataType: 'json',
            data: {
                type:2,
                type_address:typeAddress,
                cts_address:ctsAddress,
                type_num:btcNum,
                cts_exchange:ctsExchange
            },
            success: function (res) {
                if ( res.code == 1 ) {
                    $('.dhxq').fadeOut(200);
                    openAlert(res.msg);
                }else {
                    openAlert(res.msg);
                }
            }
        });
        return false;
    });
    //cam提交按钮点击事件
    $('#cam_submit').click(function () {
        var url = "{:url('home/index/assetExchange')}";
        var typeAddress = $('#fk3').val();
        var ctsAddress = $('#sk3').val();
        var camNum = $('#cts3').val();
        var camT = parseInt(t.cam_cts);
        var ctsExchange = camNum*camT;
        $.ajax({
            type: 'POST',
            url: url,
            dataType: 'json',
            data: {
                type:3,
                type_address:typeAddress,
                cts_address:ctsAddress,
                type_num:camNum,
                cts_exchange:ctsExchange
            },
            success: function (res) {
                if ( res.code == 1 ) {
                    $('.dhxq').fadeOut(200);
                    openAlert(res.msg);
                }else {
                    openAlert(res.msg);
                }
            }
        });
        return false;
    });

    //复制
    var copy = document.getElementsByClassName('copy')[0];
    copy.addEventListener('click', function() {
        if(navigator.userAgent.match(/(iPhone|iPod|iPad);?/i)) { //区分iPhone设备
            window.getSelection().removeAllRanges(); //这段代码必须放在前面否则无效
            var Url2 = document.getElementById("copyText"); //要复制文字的节点
            var range = document.createRange();
            // 选中需要复制的节点
            range.selectNode(Url2);
            // 执行选中元素
            window.getSelection().addRange(range);
            // 执行 copy 操作
            var successful = document.execCommand('copy');
            // 移除选中的元素
            window.getSelection().removeAllRanges();
            $(".tishi").show().delay(1500).fadeOut();
        } else {
            var Urltext = document.getElementById("copyText").innerText;
            var Url2 = document.getElementById("input"); //要复制文字的节点
            Url2.innerText = Urltext;
            Url2.select(); // 选择对象
            document.execCommand("Copy"); // 执行浏览器复制命令
            $(".tishi").show().delay(1500).fadeOut();
        }
    });
    $(".copy").hover(function(){
        $(".copy").attr('src','__CDN__/assets/img/scoute/web//home/icon_copy_01.png')
    },function(){
        $(".copy").attr('src','__CDN__/assets/img/scoute/web/home/icon_copy.png')
    });
    $(".yiwen").hover(function(){
        $(".yiwen").attr('src','__CDN__/assets/img/scoute/web/home/icon_mark_01.png');
        $('.daan').show(250)
    },function(){
        $(".yiwen").attr('src','__CDN__/assets/img/scoute/web/home/icon_mark.png');
        $('.daan').hide(100)
    });


//绘制圆形进度条
var canvas1 = document.getElementById("yuan1");
var canvas2 = document.getElementById("yuan2");
var canvas3 = document.getElementById("yuan3");
var canvas4 = document.getElementById("yuan4");
var canvas5 = document.getElementById("yuan5");
circleProgress(p[0].rewards,100,canvas1);
circleProgress(p[1].rewards,100,canvas2);
circleProgress(p[2].rewards,100,canvas3);
circleProgress(p[3].rewards,100,canvas4);
circleProgress(p[4].rewards,100,canvas5);

function circleProgress(value, average,dom) {
	var canvas = dom;
	canvas.width = '88';
	canvas.height = '88';
	var context = canvas.getContext('2d');
	var _this = $(canvas),
		value = Number(value), // 当前百分比,数值
		average = Number(average), // 平均百分比
		color = "", // 进度条、文字样式
		maxpercent = 100, //最大百分比，可设置
		c_width = _this.width(), // canvas，宽度
		c_height = _this.height(); // canvas,高度
	// 判断设置当前显示颜色
	if(value == maxpercent) {
		color = "#ff8317";
	} else if(value > average) {
		color = "#27b5ff";
	} else {
		color = "#ff8317";
	}
	// 清空画布
	context.clearRect(0, 0, c_width, c_height);
	// 画初始圆
	context.beginPath();
	// 将起始点移到canvas中心
	context.moveTo(c_width / 2, c_height / 2);
	// 绘制一个中心点为（c_width/2, c_height/2），半径为c_height/2，起始点0，终止点为Math.PI * 2的 整圆
	context.arc(c_width / 2, c_height / 2, c_height / 2, 0, Math.PI * 2, false);
	context.closePath();
	context.fillStyle = '#ddd'; //填充颜色
	context.fill();
	// 绘制内圆
	context.beginPath();
	context.strokeStyle = color;
	context.lineCap = 'square';
	context.closePath();
	context.fill();
	context.lineWidth = 10.0; //绘制内圆的线宽度

	function draw(cur) {
		// 画内部空白
		context.beginPath();
		context.moveTo(24, 24);
		context.arc(c_width / 2, c_height / 2, c_height / 2 - 10, 0, Math.PI * 2, true);
		context.closePath();
		context.fillStyle = 'rgba(255,255,255,1)'; // 填充内部颜色
		context.fill();
		// 画内圆
		context.beginPath();
		// 绘制一个中心点为（c_width/2, c_height/2），半径为c_height/2-5不与外圆重叠，
		// 起始点-(Math.PI/2)，终止点为((Math.PI*2)*cur)-Math.PI/2的 整圆cur为每一次绘制的距离
		context.arc(c_width / 2, c_height / 2, c_height / 2 - 5, -(Math.PI / 2), ((Math.PI * 2) * cur) - Math.PI / 2, false);
		context.stroke();
		//在中间写字
		context.font = "bold 18pt Arial"; // 字体大小，样式
		context.fillStyle = color; // 颜色
		context.textAlign = 'center'; // 位置
		context.textBaseline = 'middle';
		context.moveTo(c_width / 2, c_height / 2); // 文字填充位置
		context.fillText(value + "%", c_width / 2, c_height / 2);
//		context.fillText("正确率", c_width / 2, c_height / 2 + 20);
	}
	// 调用定时器实现动态效果
	var timer = null,
		n = 0;

	function loadCanvas(nowT) {
		timer = setInterval(function() {
			if(n > nowT) {
				clearInterval(timer);
			} else {
				draw(n);
				n += 0.01;
			}
		}, 15);
	}
	loadCanvas(value / 100);
	timer = null;
}

//进度条
var changdu = t.percentage;
function jinDu(){
	var proW = $('.pro').outerWidth();
	var percentW = $('.percent').outerWidth() / 2;
	$('.proNum').css('width',changdu + "%");
	var  percent_left= "calc("+changdu+"% - 30px)";
	$('.percent').css('left',percent_left);
	var  proD_left= "calc("+changdu+"% - 25px)";
	$('.proD').css('left',proD_left);
}jinDu()

</script>